package com.itheima.reggie.controllerApi;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.itheima.reggie.common.R;
import com.itheima.reggie.entity.Category;
import com.itheima.reggie.service.CategoryService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;


/**
 * 对接swagger API接口的
 */
@Api(description = "瑞吉外卖分类管理API")
public interface CategoryControllerApi {
    //ApiOperation 用来描述方法的注解
    @ApiOperation("添加菜品或者套餐分类")
    public R<Category> add(@RequestBody Category category);

    @ApiOperation("分页查询分类信息")
    public R findByPage(Integer page,Integer pageSize);

    @ApiOperation("根据id删除费雷")
    public R deleteById(Long id);
    /**
     * 多条模糊搜索
     */
    @ApiOperation("多条件模糊搜索")
    public R findSearch(@RequestBody Category category);
}
